const hooks = require('hooks');
// const UglifyJS = require("uglify-js");


hooks.beforeEach(function (transaction) {
    // myObject['id'] = JSON.parse(transaction.real.response);
    // console.log(transaction.request);
    transaction.request['headers']['Token'] = "2|1:0|10:1533017229|3:sid|32:NWI1ZmZjOGQyODJlZTJhNDhhMzdmOTZj|811b4c19bd03754ad86c828ca3442e56a120c6cddf50578a9439560d054b4a65";
    // var code = "function add(first, second) { return first + second; }";
    // var result = UglifyJS.parse(code);
    console.log(result.error); // runtime error, or `undefined` if no error
    console.log('=================================================');
    console.log(result);

    // console.log(transaction.expected['body'])
    // const result = UglifyJS.minify(transaction.expected['body']);
    // console.log(result);
    // transaction.expected['body'] = result
})

//
//
// after('First action', function (transaction) {
//   myObject['id'] = JSON.parse(transaction.real.response);
// });
//
//
// after('First action', function (transaction) {
//   myObject['id'] = JSON.parse(transaction.real.response);
// });

